package com.mapper;

import com.pojo.Evaluation_lfy;
import com.pojo.User_chen;
import org.apache.ibatis.annotations.*;

import java.util.List;
@Mapper
public interface User_chenMapper {
    @Select("select evaluation_content,evaluation_uid from evaluation_lfy left join user_chen on id=evaluation_uid ")
    @Results({
            @Result(column = "evaluation_content",property = "evaluationContent"),
            @Result(column = "evaluation_uid",property = "evaluationUid"),
            @Result(property = "user_chen",column = "evaluation_uid",one=@One(select = "com.mapper.User_chenMapper" +
                    ".selectText"))
    })
    List<Evaluation_lfy> selectUser();
    @Select("select nickname from user_chen where id=#{id}")
    List<User_chen> selectText(Integer id);
}
